package com.dc.adaptor.transport.ws.app;

import com.dc.adaptor.persistance.bean.SipSendPack;
import com.dc.adaptor.transport.TransportMeta;
import com.dc.adaptor.transport.TransportSender;
import com.dc.trans.steps.wsbanktax.wsclient.SjjhInterfaceStub;

public class Ws2BankTaxSender implements TransportSender {
	private Ws2BankTaxMeta meta;
	public Ws2BankTaxSender(TransportMeta meta){
		this.meta = (Ws2BankTaxMeta)meta;
	}
	@Override
	public void dispose() {
	}
	
	public Object send(SipSendPack pack) throws Exception {
		SjjhInterfaceStub stub = new SjjhInterfaceStub(meta.getIp());
		SjjhInterfaceStub.BtisSave bitSave = new SjjhInterfaceStub.BtisSave();
		bitSave.setIn0(pack.getSipContent().getContent());
		return stub.btisSave(bitSave).getOut();
	}

}
